Calculating modules in contextual logic program refinement

نویسندگان

  • Robert Colvin
  • Ian J. Hayes
  • Paul A. Strooper
چکیده

The refinement calculus for logic programs is a framework for deriving logic programs from specifications. It is based on a wide-spectrum language that can express both specifications and code, and a refinement relation that models the notion of correct implementation. In this paper we extend and generalise earlier work on contextual refinement. Contextual refinement simplifies the refinement process by abstractly capturing the context of a subcomponent of a program, which typically includes information about the values of the free variables. This paper also extends and generalises module refinement. A module is a collection of procedures that operate on a common data type; module refinement between a specification module A and an implementation module C allows calls to the procedures of A to be systematically replaced with calls to the corresponding procedures of C . Based on the conditions for module refinement, we present a method for calculating an implementation module from a specification module. Both contextual and module refinement within the refinement calculus have been generalised from earlier work and the results are presented in a unified framework.

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

منابع مشابه

A Program Logic for Contextual Refinement of Concurrent Objects under Fair Scheduling

Existing program logics on concurrent object verification either ignore progress properties, or aim for non-blocking progress (e.g., lock-freedom and wait-freedom), which cannot be applied to blocking algorithms that progress only under fair scheduling. In this paper we propose a new program logic for compositional verification of contextual refinement of concurrent objects under fair schedulin...

متن کامل

A Practical Verification Framework for Preemptive OS Kernels

We propose a practical verification framework for preemptive OS kernels. The framework models the correctness of API implementations in OS kernels as contextual refinement of their abstract specifications. It provides a specification language for defining the high-level abstract model of OS kernels, a program logic for refinement verification of concurrent kernel code with multi-level hardware ...

متن کامل

Objective: In Minimum Context

The current proposals for the inclusion of modules in the ISO Prolog standard are not very consensual. Since a program-structuring feature is required for a production programming language, several alternatives have been explored over the years. In this article we recall and expand on the concepts of Contextual Logic Programming, a powerful and simple mechanism which addresses the general issue...

متن کامل

Abstraction and Refinement for Local Reasoning

ion and Refinement for Local Reasoning Thomas Dinsdale-Young, Philippa Gardner, and Mark Wheelhouse Imperial College London {td202, pg, mjw03}@ic.ac.uk Abstract. Local reasoning has become a well-established technique in Local reasoning has become a well-established technique in program verification, which has been shown to be useful at many different levels of abstraction. In separation logic,...

متن کامل

On Structuring Contextual Logic Programs

Standardization for Prolog came during the 1990’s, initially and deliberately leaving out one aspect which is essential for real world application development: the modularity mechanism. This situation has in the meantime been remedied in the current ISO proposal for modules in Prolog. In this article we build on our previous work on Contextual Logic Programming (CxLP) and introduce mechanisms w...

متن کامل

ذخیره در منابع من


  با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید

برای دانلود متن کامل این مقاله و بیش از 32 میلیون مقاله دیگر ابتدا ثبت نام کنید

ثبت نام

اگر عضو سایت هستید لطفا وارد حساب کاربری خود شوید

عنوان ژورنال:
  • TPLP

دوره 8  شماره 

صفحات  -

تاریخ انتشار 2008